]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
workspaceThumbnails: Immediately initialize should-show
authorFlorian Müllner <fmuellner@gnome.org>
Sat, 20 Feb 2021 23:23:07 +0000 (00:23 +0100)
committerMarge Bot <marge-bot@gnome.org>
Tue, 2 Mar 2021 21:56:30 +0000 (21:56 +0000)
At the moment, we only get the initial :should-show value when populating
the thumbnails. That only happens when entering the overview, so any
listeners to notify::should-show will perceive it as a change rather
than an initialization, which can result in unwanted transitions.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>

js/ui/workspaceThumbnail.js

index fb25f6cb1fca5f08ef01ce31cde72a406264d9c4..e54e8ab1d358da4c5ace12086236e43f15a334b8 100644 (file)
@@ -684,6 +684,7 @@ var ThumbnailsBox = GObject.registerClass({
         this._settings = new Gio.Settings({ schema_id: MUTTER_SCHEMA });
         this._settings.connect('changed::dynamic-workspaces',
             () => this._updateShouldShow());
+        this._updateShouldShow();
 
         this._monitorsChangedId =
             Main.layoutManager.connect('monitors-changed', () => {
@@ -1010,8 +1011,6 @@ var ThumbnailsBox = GObject.registerClass({
             this._stateCounts[ThumbnailState[key]] = 0;
 
         this.addThumbnails(0, workspaceManager.n_workspaces);
-
-        this._updateShouldShow();
     }
 
     _destroyThumbnails() {